Optimal. Leaf size=46 \[ \frac {x}{a^2 c^2}+\frac {\cot (e+f x)}{a^2 c^2 f}-\frac {\cot ^3(e+f x)}{3 a^2 c^2 f} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.05, antiderivative size = 46, normalized size of antiderivative = 1.00, number of steps
used = 4, number of rules used = 3, integrand size = 26, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.115, Rules used = {3989, 3554, 8}
\begin {gather*} -\frac {\cot ^3(e+f x)}{3 a^2 c^2 f}+\frac {\cot (e+f x)}{a^2 c^2 f}+\frac {x}{a^2 c^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 8
Rule 3554
Rule 3989
Rubi steps
\begin {align*} \int \frac {1}{(a+a \sec (e+f x))^2 (c-c \sec (e+f x))^2} \, dx &=\frac {\int \cot ^4(e+f x) \, dx}{a^2 c^2}\\ &=-\frac {\cot ^3(e+f x)}{3 a^2 c^2 f}-\frac {\int \cot ^2(e+f x) \, dx}{a^2 c^2}\\ &=\frac {\cot (e+f x)}{a^2 c^2 f}-\frac {\cot ^3(e+f x)}{3 a^2 c^2 f}+\frac {\int 1 \, dx}{a^2 c^2}\\ &=\frac {x}{a^2 c^2}+\frac {\cot (e+f x)}{a^2 c^2 f}-\frac {\cot ^3(e+f x)}{3 a^2 c^2 f}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains higher order function than in optimal. Order 5 vs. order 3 in
optimal.
time = 0.05, size = 39, normalized size = 0.85 \begin {gather*} -\frac {\cot ^3(e+f x) \, _2F_1\left (-\frac {3}{2},1;-\frac {1}{2};-\tan ^2(e+f x)\right )}{3 a^2 c^2 f} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.12, size = 32, normalized size = 0.70
method | result | size |
default | \(\frac {-\frac {\left (\cot ^{3}\left (f x +e \right )\right )}{3}+\cot \left (f x +e \right )+f x +e}{a^{2} c^{2} f}\) | \(32\) |
risch | \(\frac {x}{a^{2} c^{2}}+\frac {4 i \left (3 \,{\mathrm e}^{4 i \left (f x +e \right )}-3 \,{\mathrm e}^{2 i \left (f x +e \right )}+2\right )}{3 f \,a^{2} c^{2} \left ({\mathrm e}^{i \left (f x +e \right )}+1\right )^{3} \left ({\mathrm e}^{i \left (f x +e \right )}-1\right )^{3}}\) | \(72\) |
norman | \(\frac {\frac {x \left (\tan ^{3}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{c a}-\frac {1}{24 a c f}+\frac {5 \left (\tan ^{2}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{8 a c f}-\frac {5 \left (\tan ^{4}\left (\frac {f x}{2}+\frac {e}{2}\right )\right )}{8 a c f}+\frac {\tan ^{6}\left (\frac {f x}{2}+\frac {e}{2}\right )}{24 a c f}}{c a \tan \left (\frac {f x}{2}+\frac {e}{2}\right )^{3}}\) | \(116\) |
derivativedivides | error in RationalFunction: argument is not a rational function\ | N/A |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.51, size = 49, normalized size = 1.07 \begin {gather*} \frac {\frac {3 \, {\left (f x + e\right )}}{a^{2} c^{2}} + \frac {3 \, \tan \left (f x + e\right )^{2} - 1}{a^{2} c^{2} \tan \left (f x + e\right )^{3}}}{3 \, f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 2.14, size = 87, normalized size = 1.89 \begin {gather*} \frac {4 \, \cos \left (f x + e\right )^{3} + 3 \, {\left (f x \cos \left (f x + e\right )^{2} - f x\right )} \sin \left (f x + e\right ) - 3 \, \cos \left (f x + e\right )}{3 \, {\left (a^{2} c^{2} f \cos \left (f x + e\right )^{2} - a^{2} c^{2} f\right )} \sin \left (f x + e\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \frac {\int \frac {1}{\sec ^{4}{\left (e + f x \right )} - 2 \sec ^{2}{\left (e + f x \right )} + 1}\, dx}{a^{2} c^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 95 vs.
\(2 (44) = 88\).
time = 0.50, size = 95, normalized size = 2.07 \begin {gather*} \frac {\frac {24 \, {\left (f x + e\right )}}{a^{2} c^{2}} + \frac {15 \, \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{2} - 1}{a^{2} c^{2} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{3}} + \frac {a^{4} c^{4} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )^{3} - 15 \, a^{4} c^{4} \tan \left (\frac {1}{2} \, f x + \frac {1}{2} \, e\right )}{a^{6} c^{6}}}{24 \, f} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 1.47, size = 58, normalized size = 1.26 \begin {gather*} -\frac {\cos \left (3\,e+3\,f\,x\right )+\frac {3\,\sin \left (3\,e+3\,f\,x\right )\,\left (e+f\,x\right )}{4}-\frac {9\,\sin \left (e+f\,x\right )\,\left (e+f\,x\right )}{4}}{3\,a^2\,c^2\,f\,{\sin \left (e+f\,x\right )}^3} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________